module.exports = {
  name: String,
  templateOwner: String,
  templateOwnerName: String,
  templateOwnerType: String,
  remark: String,
  patientInfo: {
    patientName: {
      label: String,
      value: String,
      chosen: Boolean
    },
    medicareId: {
      label: String,
      value: String,
      chosen: Boolean
    },
    cardId: {
      label: String,
      value: String,
      chosen: Boolean
    },
    sex: {
      label: String,
      value: String,
      chosen: Boolean
    },
    age: {
      label: String,
      value: String,
      chosen: Boolean
    },
    temperature: {
      label: String,
      value: String,
      chosen: Boolean
    },
    sbp: {
      label: String,
      value: String,
      chosen: Boolean
    },
    dbp: {
      label: String,
      value: String,
      chosen: Boolean
    },
    heartRate: {
      label: String,
      value: String,
      chosen: Boolean
    },
    weight: {
      label: String,
      value: String,
      chosen: Boolean
    },
    height: {
      label: String,
      value: String,
      chosen: Boolean
    },
    bmi: {
      label: String,
      value: String,
      chosen: Boolean
    },
    breath: {
      label: String,
      value: String,
      chosen: Boolean
    },
    marriage: {
      label: String,
      value: String,
      chosen: Boolean
    },
    pulse: {
      label: String,
      value: String,
      chosen: Boolean
    },
    spo2: {
      label: String,
      value: String,
      chosen: Boolean
    }
  },
  chiefComplaint: {
    data: [
      {
        part: [String],
        symptom: String,
        character: String,
        level: String,
        time: String,
        unit: String,
        chosen: Boolean,
        follow: [{
          part: String,
          symptom: String,
          character: String,
          level: String,
          time: Number,
          unit: String
        }]
      }
    ],
    mainType: [
      {
        name: String,
        type: [String]
      }
    ]
  },
  HPI: {
    situation: {
      ifNull: Boolean,
      date: String,
      cause: [String]
    },
    unusual: {
      ifNull: Boolean,
      data: [{
        hospital: String,
        name: String,
        dateTime: String,
        data: [{
          itemCode: String,
          itemName: String,
          resultValue: Number,
          startRange: Number,
          endRange: Number,
          resultUnit: String
        }]
      }]
    },
    treatment: {
      ifNull: Boolean,
      data: [{
        display: String,
        method: String,
        measure: String,
        effect: String,
        duration: Number,
        unit: String
      }]
    }
  },
  pastHistory: {
    personal: {
      ifNull: Boolean,
      data: [String]
    },
    family: {
      ifNull: Boolean,
      data: [{
        disease: String,
        sibship: String,
        age: String
      }]
    },
    surgery: {
      ifNull: Boolean,
      data: [{
        name: String,
        ID: String,
        Hospital: String
      }]
    },
    allergic: {
      ifNull: Boolean,
      data: [{
        source: String,
        reaction: String,
        level: String
      }]
    },
    menstrual: {
      ifNull: Boolean,
      firstAge: Number,
      cycle: Number,
      duration: Number,
      lastDate: String,
      endDate: String,
      endAge: Number
    },
    chronic: {
      ifNull: Boolean,
      data: [{
        disease: String,
        duration: Number,
        durationUnit: String,
        level: String
      }]
    }
  },
  PE: {
    items: {
      small: [{
        code: String,
        name: String,
        _type: String,
        max: String,
        unit: String,
        showFlag: Boolean
      }],
      big: [{
        code: String,
        name: String,
        _type: String,
        max: String,
        unit: String,
        showFlag: Boolean
      }]
    },
    values: String
  },
  checkout: {
    checked: [{
      hospital: String,
      name: String,
      dateTime: String,
      data: [{
        itemCode: String,
        itemName: String,
        resultValue: Number,
        startRange: Number,
        endRange: Number,
        resultUnit: String,
        chosen: Boolean,
        unusual: Boolean
      }]
    }],
    checking: [{
      itemCode: String,
      itemName: String,
      number: Number,
      date: String,
      urgent: Boolean,
      stackCode: String,
      stackName: String
    }],
    testing: [{
      itemCode: String,
      itemName: String,
      number: Number,
      date: String,
      urgent: Boolean,
      stackCode: String,
      stackName: String
    }]
  },
  diagnosis: [{
    diseaseCode: String,
    diseaseName: String,
    resultState: String,
    chosen: Boolean,
    _type: String
  }]
}